package com.cyx.service;

import com.cyx.mapper.UserMapper;
import com.cyx.pojo.User;


public class UserServiceImpl implements UserService {
    private UserMapper mapper;

    public void setMapper(UserMapper mapper) {
        this.mapper = mapper;
    }

    @Override
    public int addUser(User user) {
        return mapper.addUser(user);
    }

    @Override
    public int deleteUser(int userId) {
        return mapper.deleteUser(userId);
    }

    @Override
    public int doSome() {
        User user = new User(113,"jack","222");
        int ret = addUser(user);
        System.out.println(ret);
        ret = deleteUser(333);
        System.out.println(ret);
        return 0;
    }
}
